package com.pc.admin.config;

import com.pc.admin.common.MybatisInterceptor;
import org.apache.ibatis.session.SqlSessionFactory;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
 
/**
 * @author xxxx
 */
@Configuration
public class MybatisConfiguration {
 
    @Bean
    public Boolean setAutoFillValueInterceptor(SqlSessionFactory sqlSessionFactory) {
        org.apache.ibatis.session.Configuration configuration = sqlSessionFactory.getConfiguration();
        configuration.addInterceptor(new MybatisInterceptor());
        return Boolean.TRUE;
    }
 
}